﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Data.SqlClient;

public partial class AdminForm : System.Web.UI.MasterPage
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void btnSearch_Click(object sender, ImageClickEventArgs e)
    {
        string text = txtSearch.Text;
        if (DropDownList1.Text == "Special Recharge")
        {          
            SearchSR(text);
        }
    }

    private void SearchSR(string name)
    {
        SqlCommand cmd = DataProcess.Connection.CreateCommand();
        cmd.CommandText = "Select * from SpecialRecharge where name=@_packageName";
        cmd.Parameters.Add(new SqlParameter("@_packageName", name));
        cmd.ExecuteNonQuery();
    }
}
